<?php
include_once '../../vendor/autoload.php';

use Union\Pay\Factory;

date_default_timezone_set('PRC');

$config = [
    'gateway' => 'https://selfapply-test.chinaums.com',
    // 'gateway' => 'https://yinshangpai.chinaums.com',
    // 商户号
    'accesser_id' => '300015',
    // 回调验证需要的md5key
    'private_key' => 'udik876ehjde32dU61edsxsf'
];
$data = [
    'request_date' => date('YmdHis'),//请求时间
    'pic_base64' => '',
    'request_seq' => uniqid(), 
];
Factory::config($config);
// $reponse = Factory::Contract()->PicUpload()->request($data);
$reponse = Factory::Contract()->PicUpload($data);
echo 'response:' . $reponse . PHP_EOL;
